// 期数设置
// 投资进度管理 -- 投资月报表 -- 形象工程维护
import request from '@/utils/request'


export function submit(data) {
  return request({
    url: 'buss/supervisormetaphasemeasure/submit',
    method: 'post',
    data
  })
}


export function resubmit(data) {
  return request({
    url: 'buss/supervisormetaphasemeasure/resubmit',
    method: 'post',
    data
  })
}

export function del(ids) {
  return request({
    url: 'buss/supervisormetaphasemeasure/delete',
    method: 'post',
    data: ids
  })
}


export function getOne(id) {
  return request.get('buss/supervisormetaphasemeasure/getOne?id='+id)
}


export function prepareData(id) {
  return request.get('buss/supervisormetaphasemeasure/prepareData?cid='+id)
}



// 分页
export function getTablePage(data) {
  return request.post('buss/supervisormetaphasemeasure/paging', data)
}

// 根据项目查询合同树
export function getContractTreeByPid(data) {
  return request.post('buss/supervisormetaphasemeasure/getContractTreeByPid', data)
}

// 根据项目查询合同树
export function checkPhaseByMainContractId(data) {
  return request.post('buss/supervisormetaphasemeasure/checkPhaseByMainContractId', data)
}

export function getWorkbenchList(data) {
  return request.post('buss/supervisormetaphasemeasure/getWorkbenchList', data)
}


export default {
  submit,
  getOne,
  resubmit,
  del,
  getTablePage,
  getContractTreeByPid,
  prepareData, // 初始化数据
  checkPhaseByMainContractId, // 检测当前期数
  getWorkbenchList
}





